class library: Volume - use ServerBoot to send synthdef
[supercollider.git] / platform / iphone / iPhone Resources / patches / klank.rtf
blob23957a830180a978ef7cccbd5e4878a540741fef
1 {\rtf1\ansi\ansicpg1252\cocoartf949\cocoasubrtf460
2 {\fonttbl\f0\fnil\fcharset0 Monaco;}
3 {\colortbl;\red255\green255\blue255;\red0\green0\blue191;\red0\green37\blue180;}
4 \deftab720
5 \pard\pardeftab720\ql\qnatural
7 \f0\fs18 \cf2 Server\cf0 .default = \cf2 Server\cf0 .internal;\
8 s = Server.internal;\
9 s.waitForBoot(\
10 \{\
11 \pard\pardeftab560\ql\qnatural
12 \cf0    \{      \
13                 \cf3 var\cf0  freqs, ringtimes, in;\
14                 in = Amplitude.kr(RLPF.ar(AudioIn.ar(1), 100, 0.05), 0.001, 0.4);\
15                 freqs = [800, 1071, 1153, 1723] * \cf3 AccelerometerX\cf0 .kr(0.5, 2, 1);\
16                 ringtimes = [1, 1, 1, 1] * \cf3 AccelerometerY\cf0 .kr(0.1, 10, 1);\
17                 \
18                 GVerb.ar(0.5*\cf3 DynKlank\cf0 .ar(`[freqs, \cf3 nil\cf0 , ringtimes ], in*PinkNoise.ar(0.007)));\
19                 \
20         \}.play;\
21 \});}